package main

import (
	"flag"
	"fmt"
	"strings"
)

var n=flag.Bool("n",false,"omit trailing newline")//名字 默认值 描述
var sep =flag.String("s"," ","separator")
func main() { //go run echo4.go -s /  1 2 3   结果:1/2/3
	flag.Parse()//运行时必须调用，用于更新标识参数的值
	fmt.Print(strings.Join(flag.Args(),*sep))
	if !*n{
		fmt.Println()
	}
}
